package com.simple.system.domain.entity;

import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

import java.time.LocalDateTime;
import java.util.List;
import java.util.Set;

/**
 * @Description 菜单表(SysMenu)表实体类
 * @Author xiaoke
 * @Date 2024/8/10 18:00
 * @Version 1.0
 */
@SuppressWarnings("serial")
@Data
@AllArgsConstructor
@NoArgsConstructor
@TableName("sys_menu")
public class SysMenu {
    @TableId
    //主键
    private Long id;
    //父id
    private Long pid;
    //显示顺序
    @TableField(value = "`rank`")
    private Integer rank;
    //菜单名
    private String name;
    //菜单标题
    private String title;
    //外部跳转链接
    private String frameSrc;
    //权限标识符
    private String perms;
    //路由地址
    private String path;
    //是否菜单
    private Integer isMenu;
    //是否显示菜单
    private Integer showLink;
    //图标
    private String icon;
    //激活菜单的path
    private String activePath;
    //创建时间
    private LocalDateTime createTime;
    //是否缓存该页面
    private Integer keepalive;
    //更新时间
    @TableField(exist = false)
    private List<SysMenu> children;
    //角色集合
    @TableField(exist = false)
    private Set<String> roles;
}

